<script setup lang="ts">
let pageSizes=(()=>{
  let arr:Array<number>=[];
  for (let i = 0; i < 100; ) {
    i+=20;
    arr.push(i);
  }
  return arr;
})();
let page=defineModel('page');
let perpage=defineModel('perpage');
let total=defineModel('total');
const emits=defineEmits<{change():void}>()
</script>

<template>
  <div class="flex justify-end" style="margin-top: 10px;" v-if="total">
    <el-pagination
        v-model:current-page="page"
        v-model:page-size="perpage"
        @change="emits('change')"
        :page-sizes="pageSizes"
        :small="true"
        :disabled="false"
        :background="true"
        layout="total, sizes, prev, pager, next, jumper"
        :total="total"
    />
  </div>
</template>

<style scoped lang="scss">

</style>